//
//  Color.h
//  XYSfxyxuSwift
//
//  Created by 许洋 on 2018/3/11.
//  Copyright © 2018年 许洋. All rights reserved.
//

#ifndef Color_h
#define Color_h

#define Mask8(x) ( (x) & 0xFF)

#define Red(x) ( Mask8(x) )

#define Green(x) ( Mask8(x >> 8) )

#define Blue(x) ( Mask8(x >> 16) )

#define Alpha(x) ( Mask8(x >> 24) )

#define RGBAMask(r,g,b,a) ( Mask8(r) | Mask8(g) << 8 | Mask8(b) << 16 | Mask8(a) << 24)
#endif /* Color_h */
